#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include <math.h>

int main() {
	int num,count[6] = { 0 };
	scanf("%d", &num);
	while (num)
	{
		if (num >= 100)
		{
			num -= 100;
			count[0]++;
		}
		else if (num >= 50)
		{
			num -= 50;
			count[1]++;
		}
		else if (num >= 20)
		{
			num -= 20;
			count[2]++;
		}
		else if (num >= 10)
		{
			num -= 10;
			count[3]++;
		}
		else if (num >= 5)
		{
			num -= 5;
			count[4]++;
		}
		else if (num >= 1)
		{
			num -= 1;
			count[5]++;
		}
	}
	for (int i = 0; i < 6; i++)
	{
		printf("%d\n", count[i]);
	}
}